home *** CD-ROM | disk | FTP | other *** search
/ Collection of Internet / Collection of Internet.iso / msdos / lynx / source / doslynx / src / tsockvi3.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1994-10-25  |  928 b   |  34 lines

  1. //    Copyright (c) 1994, University of Kansas, All Rights Reserved
  2. //
  3. //    Class:        TSockView
  4. //    Include File:    tsockvie.h
  5. //    Purpose:    Display total amount of current network activity
  6. //    Remarks/Portability/Dependencies/Restrictions:
  7. //    Revision History:
  8. //        01-31-94    created
  9. //        02-10-94    Split all members into seperate files.
  10. #include"tsockvie.h"
  11. #include<strstrea.h>
  12. #include<iomanip.h>
  13.  
  14. void TSockView::draw()    {
  15. //    Purpose:    ReDraw the view to the display
  16. //    Arguments:    none
  17. //    Return Value:    none
  18. //    Remarks/Portability/Dependencies/Restrictions:
  19. //    Revision History:
  20. //        01-31-94    created
  21.  
  22.     TDrawBuffer TDB;
  23.     char c = getColor(2);
  24.  
  25.     //    Convert to a string.
  26.     ostrstream totalStr(SockInAscii, sizeof(SockInAscii));
  27.     totalStr << setw(12) << uli_pres << ends;
  28.  
  29.     //    First clear, then redraw the view
  30.     TDB.moveChar(0, ' ', c, size.x);
  31.     TDB.moveStr(0, SockInAscii, c);
  32.     writeLine(0, 0, size.x, 1, TDB);
  33. }
  34.